<template>
  <el-card>
    <div slot="header" class="card-header">
      <span>{{ this.$route.meta.title }}</span>
      <div class="header-select">
        <i class="el-icon-menu"></i>
        <span>选择项：</span>
        <el-select v-model="selectVal" @change="selectChange">
          <el-option
            v-for="(item, index) in selectOptions"
            :key="index"
            :label="item.title"
            :value="index"
          >
          </el-option>
        </el-select>
      </div>
    </div>
    <el-row :gutter="10" class="steps">
      <el-col
        :span="24"
        v-for="(item, index) in selectOptions[selectVal].steps"
        :key="index"
      >
        <el-card shadow="never">
          <Steps :stepArr="item"></Steps>
        </el-card>
      </el-col>
      <!-- <el-col :span="24">
        <el-card shadow="never">
          <Steps :stepArr="setpsB"></Steps>
        </el-card>
      </el-col>
      <el-col :span="24">
        <el-card shadow="never">
          <Steps :stepArr="setpsC"></Steps>
        </el-card>
      </el-col>
      <el-col :span="24">
        <el-card shadow="never">
          <Steps :stepArr="setpsD"></Steps>
        </el-card>
      </el-col> -->
    </el-row>
  </el-card>
</template>

<script>
import variable from './variable'
import Steps from './components/Steps'
export default {
  components: {
    Steps
  },

  data() {
    return {
      selectVal: 0,
      selectOptions: variable
      // setpsA: [
      //   { desc: '接口数据入HADOOP库' },
      //   { desc: '省份数据文件入到HADOOP' },
      //   { desc: '报错' }
      // ],
      // setpsB: [
      //   { desc: '接口数据重传' },
      //   { desc: '监控统一省份同一接口入库两次' },
      //   { desc: '状态为done' }
      // ],
      // setpsC: [
      //   { desc: '接口数据差异量比较' },
      //   { desc: '较上月，监控差异大于50%的省份' },
      //   { desc: '对比完成' }
      // ],
      // setpsD: [
      //   { desc: '接口数据到达时间' },
      //   { desc: '达接口机时间和入库时间监控比较，监控3天以上省份' },
      //   { desc: '监控完成' }
      // ]
    }
  },

  methods: {
    selectChange() {}
  }
}
</script>

<style lang="scss" scoped>
.steps {
  .el-card {
    margin-bottom: 10px;
  }
}
</style>
